package com.atguigu.common.exception;

/**
 * 库存不足
 */
public class NoStockException extends RuntimeException{
    //skuId
    private Long skuId;
    public NoStockException(Long skuId){
        super("商品id:"+skuId+"没有足够的库存了");
    }
    public NoStockException(String msg) {
        super(msg);
    }
    //获取skuId
    public Long getSkuId(){
        return  skuId;
    }
    //设置skuId
    public void setSkuId(Long skuId){
         this.skuId = skuId;
    }
}
